﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Xml.Serialization;

namespace WeiBOAPI.Sina
{
    public class SinaUserInfo
    {
        [XmlElement("name")]
        public string NickName
        {
            get;
            set;
        }

        [XmlElement("screen_name")]
        public string ScreenName
        {
            get;
            set;
        }

        [XmlElement("id")]
        public string Id
        {
            get;
            set;
        }

        [XmlElement("description")]
        public string Description
        {
            get;
            set;
        }

        [XmlElement("gender")]
        public string Gender
        {
            get;
            set;
        }

        [XmlElement("profile_image_url")]
        public string HeadImage
        {
            get;
            set;
        }

        [XmlElement("province")]
        public string Province
        {
            get;
            set;
        }

        [XmlElement("city")]
        public string City
        {
            get;
            set;
        }

        [XmlElement("location")]
        public string Location
        {
            get;
            set;
        }
        /// <summary>
        /// 博客地址
        /// </summary>
        [XmlElement("url")]
        public string Url
        {
            get;
            set;
        }

        /// <summary>
        /// 微博数
        /// </summary>
        [XmlElement("statuses_count")]
        public string StatusesCount
        {
            get;
            set;
        }

        /// <summary>
        /// 关注数
        /// </summary>
        [XmlElement("friends_count")]
        public string FriendsCount
        {
            get;
            set;
        }

        /// <summary>
        /// 粉丝数
        /// </summary>
        [XmlElement("followers_count")]
        public string FollowersCount
        {
            get;
            set;
        }

        [XmlElement("following")]
        public bool Following
        {
            get;
            set;
        }


        [XmlElement("verified")]
        public bool verified
        {
            get;
            set;
        }

        [XmlElement("status")]
        public SinaMessage Message
        {
            get;
            set;
        }

        public string MaxHeadImag
        {
            get
            {
                return this.HeadImage.Replace("/50/", "/180/");
            }
        }
    }
}
